package com.service.impl;

import com.dao.ClassRoomDao;
import com.pojo.ClassRoom;
import com.service.ClassRoomService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@Service
public class ClassRoomServiceImpl implements ClassRoomService {
    @Autowired
    private ClassRoomDao classRoomDao;

    @Override
    public int addClassRoom(ClassRoom classRoom) {
        return classRoomDao.addClassRoom(classRoom);
    }

    @Override
    public int deleteClassRoom(long id) {
        return classRoomDao.deleteClassRoom(id);
    }

    @Override
    public int updateClassRoom(ClassRoom classRoom) {
        return classRoomDao.updateClassRoom(classRoom);
    }

    @Override
    public List<ClassRoom> queryAllClassRoom() {
        return classRoomDao.queryAllClassRoom();
    }


    @Override
    public ClassRoom queryById(long id) {
        return classRoomDao.queryById(id);
    }
}
